import type { DeviceConfig } from './Device';

export interface DefaultHttpRequestResult {
  message: string;
  isSuccess: boolean;
}

export interface HttpRequestResult<TResult> extends DefaultHttpRequestResult {
  result: TResult;
}

export interface Target<TTask> {
  deviceId: string;
  task: TTask;
}

export interface ReadValueTask {
  deviceName: string;
  address: string;
  dataType: string;
}

export interface WriteValueTask extends ReadValueTask {
  value: string;
}

export interface DeviceConfigTask {
  deviceConfigs: DeviceConfig[];
}
